package com.omesoft.hksnore.util.file;

import com.omesoft.hksnore.util.entity.HM;

import java.util.Comparator;

/**
 * Created by Omesoft on 2017/3/5.
 *
 * 文件按时间的安排
 *
 */

public class FileComparator implements Comparator<HM> {
    public int compare(HM file1, HM file2) {
        if (file1.getLastModified() < file2.getLastModified()) {
            return 1;
        } else {
            return -1;
        }
    }
}
